<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "https://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
<meta http-equiv="X-UA-Compatible" content="IE=9"/>
<meta name="generator" content="Doxygen 1.9.1"/>
<meta name="viewport" content="width=device-width, initial-scale=1"/>
<title>uvgRTP: include/util.hh Source File</title>
<link href="tabs.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="jquery.js"></script>
<script type="text/javascript" src="dynsections.js"></script>
<link href="search/search.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="search/searchdata.js"></script>
<script type="text/javascript" src="search/search.js"></script>
<link href="doxygen.css" rel="stylesheet" type="text/css" />
</head>
<body>
<div id="top"><!-- do not remove this div, it is closed by doxygen! -->
<div id="titlearea">
<table cellspacing="0" cellpadding="0">
 <tbody>
 <tr style="height: 56px;">
  <td id="projectalign" style="padding-left: 0.5em;">
   <div id="projectname">uvgRTP
   </div>
  </td>
 </tr>
 </tbody>
</table>
</div>
<!-- end header part -->
<!-- Generated by Doxygen 1.9.1 -->
<script type="text/javascript">
/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&amp;dn=gpl-2.0.txt GPL-v2 */
var searchBox = new SearchBox("searchBox", "search",false,'Search','.html');
/* @license-end */
</script>
<script type="text/javascript" src="menudata.js"></script>
<script type="text/javascript" src="menu.js"></script>
<script type="text/javascript">
/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&amp;dn=gpl-2.0.txt GPL-v2 */
$(function() {
  initMenu('',true,false,'search.php','Search');
  $(document).ready(function() { init_search(); });
});
/* @license-end */</script>
<div id="main-nav"></div>
<!-- window showing the filter options -->
<div id="MSearchSelectWindow"
     onmouseover="return searchBox.OnSearchSelectShow()"
     onmouseout="return searchBox.OnSearchSelectHide()"
     onkeydown="return searchBox.OnSearchSelectKey(event)">
</div>

<!-- iframe showing the search results (closed by default) -->
<div id="MSearchResultsWindow">
<iframe src="javascript:void(0)" frameborder="0" 
        name="MSearchResults" id="MSearchResults">
</iframe>
</div>

<div id="nav-path" class="navpath">
  <ul>
<li class="navelem"><a class="el" href="dir_d44c64559bbebec7f509842c48db8b23.html">include</a></li>  </ul>
</div>
</div><!-- top -->
<div class="header">
  <div class="headertitle">
<div class="title">util.hh</div>  </div>
</div><!--header-->
<div class="contents">
<a href="util_8hh.html">Go to the documentation of this file.</a><div class="fragment"><div class="line"><a name="l00001"></a><span class="lineno">    1</span>&#160;<span class="preprocessor">#pragma once</span></div>
<div class="line"><a name="l00003"></a><span class="lineno">    3</span>&#160; </div>
<div class="line"><a name="l00005"></a><span class="lineno">    5</span>&#160;<span class="preprocessor">#ifdef _WIN32</span></div>
<div class="line"><a name="l00006"></a><span class="lineno">    6</span>&#160;<span class="preprocessor">#include &lt;winsock2.h&gt;</span></div>
<div class="line"><a name="l00007"></a><span class="lineno">    7</span>&#160;<span class="preprocessor">#include &lt;windows.h&gt;</span></div>
<div class="line"><a name="l00008"></a><span class="lineno">    8</span>&#160;<span class="preprocessor">#else</span></div>
<div class="line"><a name="l00009"></a><span class="lineno">    9</span>&#160;<span class="preprocessor">#include &lt;sys/time.h&gt;</span></div>
<div class="line"><a name="l00010"></a><span class="lineno">   10</span>&#160;<span class="preprocessor">#endif</span></div>
<div class="line"><a name="l00011"></a><span class="lineno">   11</span>&#160; </div>
<div class="line"><a name="l00012"></a><span class="lineno">   12</span>&#160;<span class="preprocessor">#include &lt;algorithm&gt;</span></div>
<div class="line"><a name="l00013"></a><span class="lineno">   13</span>&#160;<span class="preprocessor">#include &lt;cstdint&gt;</span></div>
<div class="line"><a name="l00014"></a><span class="lineno">   14</span>&#160;<span class="preprocessor">#include &lt;cstddef&gt;</span></div>
<div class="line"><a name="l00015"></a><span class="lineno">   15</span>&#160;<span class="preprocessor">#include &lt;cstdio&gt;</span></div>
<div class="line"><a name="l00016"></a><span class="lineno">   16</span>&#160;<span class="preprocessor">#include &lt;cstring&gt;</span></div>
<div class="line"><a name="l00017"></a><span class="lineno">   17</span>&#160;<span class="preprocessor">#include &lt;string&gt;</span></div>
<div class="line"><a name="l00018"></a><span class="lineno">   18</span>&#160; </div>
<div class="line"><a name="l00019"></a><span class="lineno">   19</span>&#160;<span class="preprocessor">#if defined(_MSC_VER)</span></div>
<div class="line"><a name="l00020"></a><span class="lineno">   20</span>&#160;<span class="keyword">typedef</span> SSIZE_T ssize_t;</div>
<div class="line"><a name="l00021"></a><span class="lineno">   21</span>&#160;<span class="preprocessor">#endif</span></div>
<div class="line"><a name="l00022"></a><span class="lineno">   22</span>&#160; </div>
<div class="line"><a name="l00023"></a><span class="lineno">   23</span>&#160;<span class="comment">/* https://stackoverflow.com/questions/1537964/visual-c-equivalent-of-gccs-attribute-packed  */</span></div>
<div class="line"><a name="l00024"></a><span class="lineno">   24</span>&#160;<span class="preprocessor">#if defined(__MINGW32__) || defined(__MINGW64__) || defined(__linux__)</span></div>
<div class="line"><a name="l00025"></a><span class="lineno">   25</span>&#160;<span class="preprocessor">#define PACK(__Declaration__) __Declaration__ __attribute__((__packed__))</span></div>
<div class="line"><a name="l00026"></a><span class="lineno">   26</span>&#160;<span class="preprocessor">#else</span></div>
<div class="line"><a name="l00027"></a><span class="lineno">   27</span>&#160;<span class="preprocessor">#define PACK(__Declaration__) __pragma(pack(push, 1)) __Declaration__ __pragma(pack(pop))</span></div>
<div class="line"><a name="l00028"></a><span class="lineno">   28</span>&#160;<span class="preprocessor">#endif</span></div>
<div class="line"><a name="l00029"></a><span class="lineno">   29</span>&#160; </div>
<div class="line"><a name="l00030"></a><span class="lineno">   30</span>&#160;<span class="preprocessor">#ifdef _WIN32</span></div>
<div class="line"><a name="l00031"></a><span class="lineno">   31</span>&#160;    <span class="keyword">typedef</span> SOCKET socket_t;</div>
<div class="line"><a name="l00032"></a><span class="lineno">   32</span>&#160;<span class="preprocessor">#else</span></div>
<div class="line"><a name="l00033"></a><span class="lineno">   33</span>&#160;    <span class="keyword">typedef</span> <span class="keywordtype">int</span> socket_t;</div>
<div class="line"><a name="l00034"></a><span class="lineno">   34</span>&#160;<span class="preprocessor">#endif</span></div>
<div class="line"><a name="l00035"></a><span class="lineno">   35</span>&#160; </div>
<div class="line"><a name="l00036"></a><span class="lineno">   36</span>&#160;<span class="keyword">const</span> <span class="keywordtype">int</span> MAX_PACKET       = 65536;</div>
<div class="line"><a name="l00037"></a><span class="lineno">   37</span>&#160;<span class="keyword">const</span> <span class="keywordtype">int</span> MAX_PAYLOAD      = 1446;</div>
<div class="line"><a name="l00038"></a><span class="lineno">   38</span>&#160;<span class="keyword">const</span> <span class="keywordtype">int</span> PKT_MAX_DELAY    = 100;</div>
<div class="line"><a name="l00039"></a><span class="lineno">   39</span>&#160; </div>
<div class="line"><a name="l00040"></a><span class="lineno">   40</span>&#160;<span class="comment">/* TODO: add ability for user to specify these? */</span></div>
<div class="line"><a name="l00041"></a><span class="lineno">   41</span>&#160;<span class="keyword">enum</span> HEADER_SIZES {</div>
<div class="line"><a name="l00042"></a><span class="lineno">   42</span>&#160;    ETH_HDR_SIZE  = 14,</div>
<div class="line"><a name="l00043"></a><span class="lineno">   43</span>&#160;    IPV4_HDR_SIZE = 20,</div>
<div class="line"><a name="l00044"></a><span class="lineno">   44</span>&#160;    UDP_HDR_SIZE  =  8,</div>
<div class="line"><a name="l00045"></a><span class="lineno">   45</span>&#160;    RTP_HDR_SIZE  = 12</div>
<div class="line"><a name="l00046"></a><span class="lineno">   46</span>&#160;};</div>
<div class="line"><a name="l00048"></a><span class="lineno">   48</span>&#160; </div>
<div class="line"><a name="l00056"></a><span class="lineno"><a class="line" href="util_8hh.html#aa6dc3f3578923d1afc40045e4cbe387b">   56</a></span>&#160;<span class="keyword">typedef</span> <span class="keyword">enum</span> <a class="code" href="util_8hh.html#aa6dc3f3578923d1afc40045e4cbe387b">RTP_ERROR</a> {</div>
<div class="line"><a name="l00057"></a><span class="lineno">   57</span>&#160;    RTP_MULTIPLE_PKTS_READY = 6,</div>
<div class="line"><a name="l00058"></a><span class="lineno">   58</span>&#160;    RTP_PKT_READY           = 5,</div>
<div class="line"><a name="l00059"></a><span class="lineno">   59</span>&#160;    RTP_PKT_MODIFIED        = 4,</div>
<div class="line"><a name="l00060"></a><span class="lineno">   60</span>&#160;    RTP_PKT_NOT_HANDLED     = 3,</div>
<div class="line"><a name="l00061"></a><span class="lineno">   61</span>&#160;    RTP_INTERRUPTED         = 2,</div>
<div class="line"><a name="l00062"></a><span class="lineno">   62</span>&#160;    RTP_NOT_READY           = 1,</div>
<div class="line"><a name="l00063"></a><span class="lineno"><a class="line" href="util_8hh.html#aa6dc3f3578923d1afc40045e4cbe387ba0d701531b2bb1c027f5e5bcc64ed29e1">   63</a></span>&#160;    <a class="code" href="util_8hh.html#aa6dc3f3578923d1afc40045e4cbe387ba0d701531b2bb1c027f5e5bcc64ed29e1">RTP_OK</a>                  = 0,    </div>
<div class="line"><a name="l00064"></a><span class="lineno"><a class="line" href="util_8hh.html#aa6dc3f3578923d1afc40045e4cbe387bafde486de26be732acf472480e3693b19">   64</a></span>&#160;    <a class="code" href="util_8hh.html#aa6dc3f3578923d1afc40045e4cbe387bafde486de26be732acf472480e3693b19">RTP_GENERIC_ERROR</a>       = -1,   </div>
<div class="line"><a name="l00065"></a><span class="lineno"><a class="line" href="util_8hh.html#aa6dc3f3578923d1afc40045e4cbe387bab392a7774c551eed903855248760ad06">   65</a></span>&#160;    <a class="code" href="util_8hh.html#aa6dc3f3578923d1afc40045e4cbe387bab392a7774c551eed903855248760ad06">RTP_SOCKET_ERROR</a>        = -2,   </div>
<div class="line"><a name="l00066"></a><span class="lineno"><a class="line" href="util_8hh.html#aa6dc3f3578923d1afc40045e4cbe387ba000c0166a0c38686389fc2eba0ddc458">   66</a></span>&#160;    <a class="code" href="util_8hh.html#aa6dc3f3578923d1afc40045e4cbe387ba000c0166a0c38686389fc2eba0ddc458">RTP_BIND_ERROR</a>          = -3,   </div>
<div class="line"><a name="l00067"></a><span class="lineno"><a class="line" href="util_8hh.html#aa6dc3f3578923d1afc40045e4cbe387ba4cdd3c5db294a4f05294b264afbf678b">   67</a></span>&#160;    <a class="code" href="util_8hh.html#aa6dc3f3578923d1afc40045e4cbe387ba4cdd3c5db294a4f05294b264afbf678b">RTP_INVALID_VALUE</a>       = -4,   </div>
<div class="line"><a name="l00068"></a><span class="lineno"><a class="line" href="util_8hh.html#aa6dc3f3578923d1afc40045e4cbe387ba6c47e86944dbed4d33531236a6e28079">   68</a></span>&#160;    <a class="code" href="util_8hh.html#aa6dc3f3578923d1afc40045e4cbe387ba6c47e86944dbed4d33531236a6e28079">RTP_SEND_ERROR</a>          = -5,   </div>
<div class="line"><a name="l00069"></a><span class="lineno"><a class="line" href="util_8hh.html#aa6dc3f3578923d1afc40045e4cbe387bac54e582250aec15bf2aea189ccbb0348">   69</a></span>&#160;    <a class="code" href="util_8hh.html#aa6dc3f3578923d1afc40045e4cbe387bac54e582250aec15bf2aea189ccbb0348">RTP_MEMORY_ERROR</a>        = -6,   </div>
<div class="line"><a name="l00070"></a><span class="lineno"><a class="line" href="util_8hh.html#aa6dc3f3578923d1afc40045e4cbe387ba80aa5b74c1e252c2ef49e0796d4183d3">   70</a></span>&#160;    <a class="code" href="util_8hh.html#aa6dc3f3578923d1afc40045e4cbe387ba80aa5b74c1e252c2ef49e0796d4183d3">RTP_SSRC_COLLISION</a>      = -7,   </div>
<div class="line"><a name="l00071"></a><span class="lineno"><a class="line" href="util_8hh.html#aa6dc3f3578923d1afc40045e4cbe387ba0759e9bb74c7a15ef09513547ed5cc2a">   71</a></span>&#160;    <a class="code" href="util_8hh.html#aa6dc3f3578923d1afc40045e4cbe387ba0759e9bb74c7a15ef09513547ed5cc2a">RTP_INITIALIZED</a>         = -8,   </div>
<div class="line"><a name="l00072"></a><span class="lineno"><a class="line" href="util_8hh.html#aa6dc3f3578923d1afc40045e4cbe387ba32d67254c4da35568e7007ec3825f98a">   72</a></span>&#160;    <a class="code" href="util_8hh.html#aa6dc3f3578923d1afc40045e4cbe387ba32d67254c4da35568e7007ec3825f98a">RTP_NOT_INITIALIZED</a>     = -9,   </div>
<div class="line"><a name="l00073"></a><span class="lineno"><a class="line" href="util_8hh.html#aa6dc3f3578923d1afc40045e4cbe387ba756d5cd372b045f069a493ed2f2cfa22">   73</a></span>&#160;    <a class="code" href="util_8hh.html#aa6dc3f3578923d1afc40045e4cbe387ba756d5cd372b045f069a493ed2f2cfa22">RTP_NOT_SUPPORTED</a>       = -10,  </div>
<div class="line"><a name="l00074"></a><span class="lineno"><a class="line" href="util_8hh.html#aa6dc3f3578923d1afc40045e4cbe387baa499befa487c22503360adffc590f33b">   74</a></span>&#160;    <a class="code" href="util_8hh.html#aa6dc3f3578923d1afc40045e4cbe387baa499befa487c22503360adffc590f33b">RTP_RECV_ERROR</a>          = -11,  </div>
<div class="line"><a name="l00075"></a><span class="lineno"><a class="line" href="util_8hh.html#aa6dc3f3578923d1afc40045e4cbe387bacb40716d1ab0663c0cce56f6d03f0902">   75</a></span>&#160;    <a class="code" href="util_8hh.html#aa6dc3f3578923d1afc40045e4cbe387bacb40716d1ab0663c0cce56f6d03f0902">RTP_TIMEOUT</a>             = -12,  </div>
<div class="line"><a name="l00076"></a><span class="lineno"><a class="line" href="util_8hh.html#aa6dc3f3578923d1afc40045e4cbe387ba0a18f9856d2dd5890bb6ec25e4acf631">   76</a></span>&#160;    <a class="code" href="util_8hh.html#aa6dc3f3578923d1afc40045e4cbe387ba0a18f9856d2dd5890bb6ec25e4acf631">RTP_NOT_FOUND</a>           = -13,  </div>
<div class="line"><a name="l00077"></a><span class="lineno"><a class="line" href="util_8hh.html#aa6dc3f3578923d1afc40045e4cbe387ba6d62ec0a7250a3db7c0f3a13280ecc65">   77</a></span>&#160;    <a class="code" href="util_8hh.html#aa6dc3f3578923d1afc40045e4cbe387ba6d62ec0a7250a3db7c0f3a13280ecc65">RTP_AUTH_TAG_MISMATCH</a>   = -14,  </div>
<div class="line"><a name="l00078"></a><span class="lineno">   78</span>&#160;} rtp_error_t;</div>
<div class="line"><a name="l00079"></a><span class="lineno">   79</span>&#160; </div>
<div class="line"><a name="l00085"></a><span class="lineno"><a class="line" href="util_8hh.html#a313c6640ac5ed9384184a94ec57a9a96">   85</a></span>&#160;<span class="keyword">typedef</span> <span class="keyword">enum</span> <a class="code" href="util_8hh.html#a313c6640ac5ed9384184a94ec57a9a96">RTP_FORMAT</a> {</div>
<div class="line"><a name="l00086"></a><span class="lineno"><a class="line" href="util_8hh.html#a313c6640ac5ed9384184a94ec57a9a96ad4b1be929d880baa2c2ca85c614f61b9">   86</a></span>&#160;    <a class="code" href="util_8hh.html#a313c6640ac5ed9384184a94ec57a9a96ad4b1be929d880baa2c2ca85c614f61b9">RTP_FORMAT_GENERIC</a> = 0,   </div>
<div class="line"><a name="l00087"></a><span class="lineno"><a class="line" href="util_8hh.html#a313c6640ac5ed9384184a94ec57a9a96ad785025a8de9a53f17dc84ec3eed85bd">   87</a></span>&#160;    <a class="code" href="util_8hh.html#a313c6640ac5ed9384184a94ec57a9a96ad785025a8de9a53f17dc84ec3eed85bd">RTP_FORMAT_H264</a>    = 95,  </div>
<div class="line"><a name="l00088"></a><span class="lineno"><a class="line" href="util_8hh.html#a313c6640ac5ed9384184a94ec57a9a96a4ee0ab7d51bf50f8f5a5cb995ecc407b">   88</a></span>&#160;    <a class="code" href="util_8hh.html#a313c6640ac5ed9384184a94ec57a9a96a4ee0ab7d51bf50f8f5a5cb995ecc407b">RTP_FORMAT_H265</a>    = 96,  </div>
<div class="line"><a name="l00089"></a><span class="lineno"><a class="line" href="util_8hh.html#a313c6640ac5ed9384184a94ec57a9a96a0e3d0414b29804783324399c8a42c85d">   89</a></span>&#160;    <a class="code" href="util_8hh.html#a313c6640ac5ed9384184a94ec57a9a96a0e3d0414b29804783324399c8a42c85d">RTP_FORMAT_H266</a>    = 97,  </div>
<div class="line"><a name="l00090"></a><span class="lineno"><a class="line" href="util_8hh.html#a313c6640ac5ed9384184a94ec57a9a96a4e6ef095b4645cdc8aef241aad1f974b">   90</a></span>&#160;    <a class="code" href="util_8hh.html#a313c6640ac5ed9384184a94ec57a9a96a4e6ef095b4645cdc8aef241aad1f974b">RTP_FORMAT_OPUS</a>    = 98,  </div>
<div class="line"><a name="l00091"></a><span class="lineno">   91</span>&#160;} rtp_format_t;</div>
<div class="line"><a name="l00092"></a><span class="lineno">   92</span>&#160; </div>
<div class="line"><a name="l00099"></a><span class="lineno"><a class="line" href="util_8hh.html#af03a75996471fc531742cd640c7caf2d">   99</a></span>&#160;<span class="keyword">typedef</span> <span class="keyword">enum</span> <a class="code" href="util_8hh.html#af03a75996471fc531742cd640c7caf2d">RTP_FLAGS</a> {</div>
<div class="line"><a name="l00101"></a><span class="lineno"><a class="line" href="util_8hh.html#af03a75996471fc531742cd640c7caf2da084c095dae54bbbc6d9509568c58f9a6">  101</a></span>&#160;    <a class="code" href="util_8hh.html#af03a75996471fc531742cd640c7caf2da084c095dae54bbbc6d9509568c58f9a6">RTP_NO_FLAGS</a> = 0 &lt;&lt; 0,</div>
<div class="line"><a name="l00102"></a><span class="lineno">  102</span>&#160; </div>
<div class="line"><a name="l00104"></a><span class="lineno"><a class="line" href="util_8hh.html#af03a75996471fc531742cd640c7caf2dada7e8bc5f5542554ad7de9d74967616f">  104</a></span>&#160;    <a class="code" href="util_8hh.html#af03a75996471fc531742cd640c7caf2dada7e8bc5f5542554ad7de9d74967616f">RTP_SLICE</a>    = 1 &lt;&lt; 0,</div>
<div class="line"><a name="l00105"></a><span class="lineno">  105</span>&#160; </div>
<div class="line"><a name="l00107"></a><span class="lineno">  107</span>&#160;    <a class="code" href="util_8hh.html#af03a75996471fc531742cd640c7caf2dab1d5797a23c37a33168046a2ae6aef6a">RTP_COPY</a>     = 1 &lt;&lt; 1</div>
<div class="line"><a name="l00108"></a><span class="lineno">  108</span>&#160; </div>
<div class="line"><a name="l00109"></a><span class="lineno"><a class="line" href="util_8hh.html#af03a75996471fc531742cd640c7caf2dab1d5797a23c37a33168046a2ae6aef6a">  109</a></span>&#160;} rtp_flags_t;</div>
<div class="line"><a name="l00110"></a><span class="lineno">  110</span>&#160; </div>
<div class="line"><a name="l00118"></a><span class="lineno"><a class="line" href="util_8hh.html#a15b2d6364db6065a482c99827f4bd2af">  118</a></span>&#160;<span class="keyword">enum</span> <a class="code" href="util_8hh.html#a15b2d6364db6065a482c99827f4bd2af">RTP_CTX_ENABLE_FLAGS</a> {</div>
<div class="line"><a name="l00119"></a><span class="lineno">  119</span>&#160;    RCE_NO_FLAGS                  = 0 &lt;&lt; 0,</div>
<div class="line"><a name="l00120"></a><span class="lineno">  120</span>&#160; </div>
<div class="line"><a name="l00121"></a><span class="lineno">  121</span>&#160;    <span class="comment">/* Enable system call dispatcher (HEVC only) */</span></div>
<div class="line"><a name="l00122"></a><span class="lineno">  122</span>&#160;    RCE_SYSTEM_CALL_DISPATCHER    = 1 &lt;&lt; 2,</div>
<div class="line"><a name="l00123"></a><span class="lineno">  123</span>&#160; </div>
<div class="line"><a name="l00125"></a><span class="lineno"><a class="line" href="util_8hh.html#a15b2d6364db6065a482c99827f4bd2afaf235cba606675b9c38284ee1a491696b">  125</a></span>&#160;    <a class="code" href="util_8hh.html#a15b2d6364db6065a482c99827f4bd2afaf235cba606675b9c38284ee1a491696b">RCE_SRTP</a>                      = 1 &lt;&lt; 3,</div>
<div class="line"><a name="l00126"></a><span class="lineno">  126</span>&#160; </div>
<div class="line"><a name="l00135"></a><span class="lineno"><a class="line" href="util_8hh.html#a15b2d6364db6065a482c99827f4bd2afa40a3deab3893524daf7e057c6dfdaa75">  135</a></span>&#160;    <a class="code" href="util_8hh.html#a15b2d6364db6065a482c99827f4bd2afa40a3deab3893524daf7e057c6dfdaa75">RCE_SRTP_KMNGMNT_ZRTP</a>         = 1 &lt;&lt; 4,</div>
<div class="line"><a name="l00136"></a><span class="lineno">  136</span>&#160; </div>
<div class="line"><a name="l00145"></a><span class="lineno"><a class="line" href="util_8hh.html#a15b2d6364db6065a482c99827f4bd2afa4722105b4fd34467a56b8aca8fc03773">  145</a></span>&#160;    <a class="code" href="util_8hh.html#a15b2d6364db6065a482c99827f4bd2afa4722105b4fd34467a56b8aca8fc03773">RCE_SRTP_KMNGMNT_USER</a>         = 1 &lt;&lt; 5,</div>
<div class="line"><a name="l00146"></a><span class="lineno">  146</span>&#160; </div>
<div class="line"><a name="l00167"></a><span class="lineno"><a class="line" href="util_8hh.html#a15b2d6364db6065a482c99827f4bd2afa5e9f19a63c964806ac9ff4ee089745e0">  167</a></span>&#160;    <a class="code" href="util_8hh.html#a15b2d6364db6065a482c99827f4bd2afa5e9f19a63c964806ac9ff4ee089745e0">RCE_NO_H26X_INTRA_DELAY</a>       = 1 &lt;&lt; 5,</div>
<div class="line"><a name="l00168"></a><span class="lineno">  168</span>&#160; </div>
<div class="line"><a name="l00181"></a><span class="lineno"><a class="line" href="util_8hh.html#a15b2d6364db6065a482c99827f4bd2afa5b0a8dbb22c20ebe8c0711541fb68a79">  181</a></span>&#160;    <a class="code" href="util_8hh.html#a15b2d6364db6065a482c99827f4bd2afa5b0a8dbb22c20ebe8c0711541fb68a79">RCE_FRAGMENT_GENERIC</a>          = 1 &lt;&lt; 6,</div>
<div class="line"><a name="l00182"></a><span class="lineno">  182</span>&#160; </div>
<div class="line"><a name="l00191"></a><span class="lineno"><a class="line" href="util_8hh.html#a15b2d6364db6065a482c99827f4bd2afa38c61eb2382a39b82fdacb7ae832bdd8">  191</a></span>&#160;    <a class="code" href="util_8hh.html#a15b2d6364db6065a482c99827f4bd2afa38c61eb2382a39b82fdacb7ae832bdd8">RCE_SRTP_INPLACE_ENCRYPTION</a>   = 1 &lt;&lt; 7,</div>
<div class="line"><a name="l00192"></a><span class="lineno">  192</span>&#160; </div>
<div class="line"><a name="l00194"></a><span class="lineno"><a class="line" href="util_8hh.html#a15b2d6364db6065a482c99827f4bd2afac03160668b92662fcb8d5b27bca3fbb0">  194</a></span>&#160;    <a class="code" href="util_8hh.html#a15b2d6364db6065a482c99827f4bd2afac03160668b92662fcb8d5b27bca3fbb0">RCE_NO_SYSTEM_CALL_CLUSTERING</a> = 1 &lt;&lt; 8,</div>
<div class="line"><a name="l00195"></a><span class="lineno">  195</span>&#160; </div>
<div class="line"><a name="l00197"></a><span class="lineno"><a class="line" href="util_8hh.html#a15b2d6364db6065a482c99827f4bd2afa4ddec7d182cec161d6b582589bc9baba">  197</a></span>&#160;    <a class="code" href="util_8hh.html#a15b2d6364db6065a482c99827f4bd2afa4ddec7d182cec161d6b582589bc9baba">RCE_SRTP_NULL_CIPHER</a>          = 1 &lt;&lt; 9,</div>
<div class="line"><a name="l00198"></a><span class="lineno">  198</span>&#160; </div>
<div class="line"><a name="l00205"></a><span class="lineno"><a class="line" href="util_8hh.html#a15b2d6364db6065a482c99827f4bd2afa820625b96886d955bc42e0cbc52cdd1e">  205</a></span>&#160;    <a class="code" href="util_8hh.html#a15b2d6364db6065a482c99827f4bd2afa820625b96886d955bc42e0cbc52cdd1e">RCE_SRTP_AUTHENTICATE_RTP</a>     = 1 &lt;&lt; 10,</div>
<div class="line"><a name="l00206"></a><span class="lineno">  206</span>&#160; </div>
<div class="line"><a name="l00208"></a><span class="lineno"><a class="line" href="util_8hh.html#a15b2d6364db6065a482c99827f4bd2afaddd5fdb170d7cc194e4165d3f9e9a1c1">  208</a></span>&#160;    <a class="code" href="util_8hh.html#a15b2d6364db6065a482c99827f4bd2afaddd5fdb170d7cc194e4165d3f9e9a1c1">RCE_SRTP_REPLAY_PROTECTION</a>    = 1 &lt;&lt; 11,</div>
<div class="line"><a name="l00209"></a><span class="lineno">  209</span>&#160; </div>
<div class="line"><a name="l00212"></a><span class="lineno"><a class="line" href="util_8hh.html#a15b2d6364db6065a482c99827f4bd2afab1342138e5af3f03d6eaf1378382bf3d">  212</a></span>&#160;    <a class="code" href="util_8hh.html#a15b2d6364db6065a482c99827f4bd2afab1342138e5af3f03d6eaf1378382bf3d">RCE_RTCP</a>                      = 1 &lt;&lt; 12,</div>
<div class="line"><a name="l00213"></a><span class="lineno">  213</span>&#160; </div>
<div class="line"><a name="l00215"></a><span class="lineno"><a class="line" href="util_8hh.html#a15b2d6364db6065a482c99827f4bd2afa75a655a9170ae88e07e993c1dd7ca4f7">  215</a></span>&#160;    <a class="code" href="util_8hh.html#a15b2d6364db6065a482c99827f4bd2afa75a655a9170ae88e07e993c1dd7ca4f7">RCE_H26X_PREPEND_SC</a>           = 1 &lt;&lt; 13,</div>
<div class="line"><a name="l00216"></a><span class="lineno">  216</span>&#160; </div>
<div class="line"><a name="l00221"></a><span class="lineno"><a class="line" href="util_8hh.html#a15b2d6364db6065a482c99827f4bd2afa8e66f45819774772a0156647d3788a95">  221</a></span>&#160;    <a class="code" href="util_8hh.html#a15b2d6364db6065a482c99827f4bd2afa8e66f45819774772a0156647d3788a95">RCE_HOLEPUNCH_KEEPALIVE</a>       = 1 &lt;&lt; 14,</div>
<div class="line"><a name="l00222"></a><span class="lineno">  222</span>&#160; </div>
<div class="line"><a name="l00224"></a><span class="lineno"><a class="line" href="util_8hh.html#a15b2d6364db6065a482c99827f4bd2afaedeac11cc80833b61b51ae32f787db73">  224</a></span>&#160;    <a class="code" href="util_8hh.html#a15b2d6364db6065a482c99827f4bd2afaedeac11cc80833b61b51ae32f787db73">RCE_SRTP_KEYSIZE_192</a>          = 1 &lt;&lt; 15,</div>
<div class="line"><a name="l00225"></a><span class="lineno">  225</span>&#160; </div>
<div class="line"><a name="l00227"></a><span class="lineno"><a class="line" href="util_8hh.html#a15b2d6364db6065a482c99827f4bd2afa163744fe7c054b8396a4a07ae82a80c0">  227</a></span>&#160;    <a class="code" href="util_8hh.html#a15b2d6364db6065a482c99827f4bd2afa163744fe7c054b8396a4a07ae82a80c0">RCE_SRTP_KEYSIZE_256</a>          = 1 &lt;&lt; 16,</div>
<div class="line"><a name="l00228"></a><span class="lineno">  228</span>&#160; </div>
<div class="line"><a name="l00229"></a><span class="lineno">  229</span>&#160;    RCE_LAST                      = 1 &lt;&lt; 17,</div>
<div class="line"><a name="l00230"></a><span class="lineno">  230</span>&#160;};</div>
<div class="line"><a name="l00231"></a><span class="lineno">  231</span>&#160; </div>
<div class="line"><a name="l00239"></a><span class="lineno"><a class="line" href="util_8hh.html#aa98d9238629e33567e73af0d239e587f">  239</a></span>&#160;<span class="keyword">enum</span> <a class="code" href="util_8hh.html#aa98d9238629e33567e73af0d239e587f">RTP_CTX_CONFIGURATION_FLAGS</a> {</div>
<div class="line"><a name="l00240"></a><span class="lineno">  240</span>&#160;    RCC_NO_FLAGS         = 0,</div>
<div class="line"><a name="l00241"></a><span class="lineno">  241</span>&#160; </div>
<div class="line"><a name="l00248"></a><span class="lineno"><a class="line" href="util_8hh.html#aa98d9238629e33567e73af0d239e587fac52afca9d1a8c24b1a788bc5b8524663">  248</a></span>&#160;    <a class="code" href="util_8hh.html#aa98d9238629e33567e73af0d239e587fac52afca9d1a8c24b1a788bc5b8524663">RCC_UDP_RCV_BUF_SIZE</a> = 1,</div>
<div class="line"><a name="l00249"></a><span class="lineno">  249</span>&#160; </div>
<div class="line"><a name="l00256"></a><span class="lineno"><a class="line" href="util_8hh.html#aa98d9238629e33567e73af0d239e587fad4eba6c62183db35dd4bd0e09ddd107b">  256</a></span>&#160;    <a class="code" href="util_8hh.html#aa98d9238629e33567e73af0d239e587fad4eba6c62183db35dd4bd0e09ddd107b">RCC_UDP_SND_BUF_SIZE</a> = 2,</div>
<div class="line"><a name="l00257"></a><span class="lineno">  257</span>&#160; </div>
<div class="line"><a name="l00264"></a><span class="lineno"><a class="line" href="util_8hh.html#aa98d9238629e33567e73af0d239e587fa5ac1245e18a420489083adddfa97b135">  264</a></span>&#160;    <a class="code" href="util_8hh.html#aa98d9238629e33567e73af0d239e587fa5ac1245e18a420489083adddfa97b135">RCC_PKT_MAX_DELAY</a>    = 3,</div>
<div class="line"><a name="l00265"></a><span class="lineno">  265</span>&#160; </div>
<div class="line"><a name="l00268"></a><span class="lineno"><a class="line" href="util_8hh.html#aa98d9238629e33567e73af0d239e587fac758a522806ada30386b262660f30617">  268</a></span>&#160;    <a class="code" href="util_8hh.html#aa98d9238629e33567e73af0d239e587fac758a522806ada30386b262660f30617">RCC_DYN_PAYLOAD_TYPE</a> = 4,</div>
<div class="line"><a name="l00269"></a><span class="lineno">  269</span>&#160; </div>
<div class="line"><a name="l00278"></a><span class="lineno"><a class="line" href="util_8hh.html#aa98d9238629e33567e73af0d239e587fa7667fb72b42a2c11991b4879619f9f83">  278</a></span>&#160;    <a class="code" href="util_8hh.html#aa98d9238629e33567e73af0d239e587fa7667fb72b42a2c11991b4879619f9f83">RCC_MTU_SIZE</a>         = 5,</div>
<div class="line"><a name="l00279"></a><span class="lineno">  279</span>&#160; </div>
<div class="line"><a name="l00280"></a><span class="lineno">  280</span>&#160;    RCC_LAST</div>
<div class="line"><a name="l00281"></a><span class="lineno">  281</span>&#160;};</div>
<div class="line"><a name="l00282"></a><span class="lineno">  282</span>&#160; </div>
<div class="line"><a name="l00284"></a><span class="lineno">  284</span>&#160;<span class="keyword">enum</span> NOTIFY_REASON {</div>
<div class="line"><a name="l00285"></a><span class="lineno">  285</span>&#160; </div>
<div class="line"><a name="l00286"></a><span class="lineno">  286</span>&#160;    <span class="comment">/* Timer for the active frame has expired and it has been dropped */</span></div>
<div class="line"><a name="l00287"></a><span class="lineno">  287</span>&#160;    NR_FRAME_DROPPED = 0,</div>
<div class="line"><a name="l00288"></a><span class="lineno">  288</span>&#160;};</div>
<div class="line"><a name="l00289"></a><span class="lineno">  289</span>&#160; </div>
<div class="line"><a name="l00290"></a><span class="lineno">  290</span>&#160;<span class="comment">/* see src/util.hh for more information */</span></div>
<div class="line"><a name="l00291"></a><span class="lineno">  291</span>&#160;<span class="keyword">typedef</span> <span class="keyword">struct </span>rtp_ctx_conf {</div>
<div class="line"><a name="l00292"></a><span class="lineno">  292</span>&#160;    <span class="keywordtype">int</span> flags;</div>
<div class="line"><a name="l00293"></a><span class="lineno">  293</span>&#160;    ssize_t ctx_values[RCC_LAST];</div>
<div class="line"><a name="l00294"></a><span class="lineno">  294</span>&#160;} rtp_ctx_conf_t;</div>
<div class="line"><a name="l00295"></a><span class="lineno">  295</span>&#160; </div>
<div class="line"><a name="l00296"></a><span class="lineno">  296</span>&#160;<span class="keyword">extern</span> thread_local rtp_error_t rtp_errno;</div>
<div class="line"><a name="l00297"></a><span class="lineno">  297</span>&#160; </div>
<div class="line"><a name="l00298"></a><span class="lineno">  298</span>&#160;<span class="preprocessor">#define TIME_DIFF(s, e, u) ((ssize_t)std::chrono::duration_cast&lt;std::chrono::u&gt;(e - s).count())</span></div>
<div class="line"><a name="l00299"></a><span class="lineno">  299</span>&#160; </div>
<div class="line"><a name="l00300"></a><span class="lineno">  300</span>&#160;<span class="preprocessor">#define SET_NEXT_FIELD_32(a, p, v) do { *(uint32_t *)&amp;(a)[p] = (v); p += 4; } while (0)</span></div>
<div class="line"><a name="l00301"></a><span class="lineno">  301</span>&#160;<span class="preprocessor">#define SET_FIELD_32(a, i, v)      do { *(uint32_t *)&amp;(a)[i] = (v); } while (0)</span></div>
<div class="line"><a name="l00302"></a><span class="lineno">  302</span>&#160; </div>
<div class="line"><a name="l00303"></a><span class="lineno">  303</span>&#160;<span class="keyword">static</span> <span class="keyword">inline</span> <span class="keywordtype">void</span> hex_dump(uint8_t *buf, <span class="keywordtype">size_t</span> len)</div>
<div class="line"><a name="l00304"></a><span class="lineno">  304</span>&#160;{</div>
<div class="line"><a name="l00305"></a><span class="lineno">  305</span>&#160;    <span class="keywordflow">if</span> (!buf)</div>
<div class="line"><a name="l00306"></a><span class="lineno">  306</span>&#160;        <span class="keywordflow">return</span>;</div>
<div class="line"><a name="l00307"></a><span class="lineno">  307</span>&#160; </div>
<div class="line"><a name="l00308"></a><span class="lineno">  308</span>&#160;    <span class="keywordflow">for</span> (<span class="keywordtype">size_t</span> i = 0; i &lt; len; i += 10) {</div>
<div class="line"><a name="l00309"></a><span class="lineno">  309</span>&#160;        fprintf(stderr, <span class="stringliteral">&quot;\t&quot;</span>);</div>
<div class="line"><a name="l00310"></a><span class="lineno">  310</span>&#160;        <span class="keywordflow">for</span> (<span class="keywordtype">size_t</span> k = i; k &lt; i + 10; ++k) {</div>
<div class="line"><a name="l00311"></a><span class="lineno">  311</span>&#160;            fprintf(stderr, <span class="stringliteral">&quot;0x%02x &quot;</span>, buf[k]);</div>
<div class="line"><a name="l00312"></a><span class="lineno">  312</span>&#160;        }</div>
<div class="line"><a name="l00313"></a><span class="lineno">  313</span>&#160;        fprintf(stderr, <span class="stringliteral">&quot;\n&quot;</span>);</div>
<div class="line"><a name="l00314"></a><span class="lineno">  314</span>&#160;    }</div>
<div class="line"><a name="l00315"></a><span class="lineno">  315</span>&#160;}</div>
<div class="line"><a name="l00316"></a><span class="lineno">  316</span>&#160; </div>
<div class="line"><a name="l00317"></a><span class="lineno">  317</span>&#160;<span class="keyword">static</span> <span class="keyword">inline</span> <span class="keywordtype">void</span> set_bytes(<span class="keywordtype">int</span> *ptr, <span class="keywordtype">int</span> nbytes)</div>
<div class="line"><a name="l00318"></a><span class="lineno">  318</span>&#160;{</div>
<div class="line"><a name="l00319"></a><span class="lineno">  319</span>&#160;    <span class="keywordflow">if</span> (ptr)</div>
<div class="line"><a name="l00320"></a><span class="lineno">  320</span>&#160;        *ptr = nbytes;</div>
<div class="line"><a name="l00321"></a><span class="lineno">  321</span>&#160;}</div>
<div class="line"><a name="l00322"></a><span class="lineno">  322</span>&#160; </div>
<div class="line"><a name="l00323"></a><span class="lineno">  323</span>&#160;<span class="keyword">static</span> <span class="keyword">inline</span> <span class="keywordtype">void</span> *memdup(<span class="keyword">const</span> <span class="keywordtype">void</span> *src, <span class="keywordtype">size_t</span> len)</div>
<div class="line"><a name="l00324"></a><span class="lineno">  324</span>&#160;{</div>
<div class="line"><a name="l00325"></a><span class="lineno">  325</span>&#160;    uint8_t *dst = <span class="keyword">new</span> uint8_t[len];</div>
<div class="line"><a name="l00326"></a><span class="lineno">  326</span>&#160;    std::memcpy(dst, src, len);</div>
<div class="line"><a name="l00327"></a><span class="lineno">  327</span>&#160; </div>
<div class="line"><a name="l00328"></a><span class="lineno">  328</span>&#160;    <span class="keywordflow">return</span> dst;</div>
<div class="line"><a name="l00329"></a><span class="lineno">  329</span>&#160;}</div>
<div class="line"><a name="l00330"></a><span class="lineno">  330</span>&#160; </div>
<div class="line"><a name="l00331"></a><span class="lineno">  331</span>&#160;<span class="keyword">static</span> <span class="keyword">inline</span> std::string generate_string(<span class="keywordtype">size_t</span> length)</div>
<div class="line"><a name="l00332"></a><span class="lineno">  332</span>&#160;{</div>
<div class="line"><a name="l00333"></a><span class="lineno">  333</span>&#160;    <span class="keyword">auto</span> randchar = []() -&gt; <span class="keywordtype">char</span></div>
<div class="line"><a name="l00334"></a><span class="lineno">  334</span>&#160;    {</div>
<div class="line"><a name="l00335"></a><span class="lineno">  335</span>&#160;        <span class="keyword">const</span> <span class="keywordtype">char</span> charset[] =</div>
<div class="line"><a name="l00336"></a><span class="lineno">  336</span>&#160;        <span class="stringliteral">&quot;0123456789&quot;</span></div>
<div class="line"><a name="l00337"></a><span class="lineno">  337</span>&#160;        <span class="stringliteral">&quot;ABCDEFGHIJKLMNOPQRSTUVWXYZ&quot;</span></div>
<div class="line"><a name="l00338"></a><span class="lineno">  338</span>&#160;        <span class="stringliteral">&quot;abcdefghijklmnopqrstuvwxyz&quot;</span>;</div>
<div class="line"><a name="l00339"></a><span class="lineno">  339</span>&#160;        <span class="keyword">const</span> <span class="keywordtype">size_t</span> max_index = (<span class="keyword">sizeof</span>(charset) - 1);</div>
<div class="line"><a name="l00340"></a><span class="lineno">  340</span>&#160;        <span class="keywordflow">return</span> charset[ rand() % max_index ];</div>
<div class="line"><a name="l00341"></a><span class="lineno">  341</span>&#160;    };</div>
<div class="line"><a name="l00342"></a><span class="lineno">  342</span>&#160; </div>
<div class="line"><a name="l00343"></a><span class="lineno">  343</span>&#160;    std::string str(length, 0);</div>
<div class="line"><a name="l00344"></a><span class="lineno">  344</span>&#160;    std::generate_n(str.begin(), length, randchar);</div>
<div class="line"><a name="l00345"></a><span class="lineno">  345</span>&#160;    <span class="keywordflow">return</span> str;</div>
<div class="line"><a name="l00346"></a><span class="lineno">  346</span>&#160;}</div>
<div class="ttc" id="autil_8hh_html_a15b2d6364db6065a482c99827f4bd2af"><div class="ttname"><a href="util_8hh.html#a15b2d6364db6065a482c99827f4bd2af">RTP_CTX_ENABLE_FLAGS</a></div><div class="ttdeci">RTP_CTX_ENABLE_FLAGS</div><div class="ttdoc">RTP context enable flags.</div><div class="ttdef"><b>Definition:</b> util.hh:118</div></div>
<div class="ttc" id="autil_8hh_html_a15b2d6364db6065a482c99827f4bd2afa163744fe7c054b8396a4a07ae82a80c0"><div class="ttname"><a href="util_8hh.html#a15b2d6364db6065a482c99827f4bd2afa163744fe7c054b8396a4a07ae82a80c0">RCE_SRTP_KEYSIZE_256</a></div><div class="ttdeci">@ RCE_SRTP_KEYSIZE_256</div><div class="ttdef"><b>Definition:</b> util.hh:227</div></div>
<div class="ttc" id="autil_8hh_html_a15b2d6364db6065a482c99827f4bd2afa38c61eb2382a39b82fdacb7ae832bdd8"><div class="ttname"><a href="util_8hh.html#a15b2d6364db6065a482c99827f4bd2afa38c61eb2382a39b82fdacb7ae832bdd8">RCE_SRTP_INPLACE_ENCRYPTION</a></div><div class="ttdeci">@ RCE_SRTP_INPLACE_ENCRYPTION</div><div class="ttdef"><b>Definition:</b> util.hh:191</div></div>
<div class="ttc" id="autil_8hh_html_a15b2d6364db6065a482c99827f4bd2afa40a3deab3893524daf7e057c6dfdaa75"><div class="ttname"><a href="util_8hh.html#a15b2d6364db6065a482c99827f4bd2afa40a3deab3893524daf7e057c6dfdaa75">RCE_SRTP_KMNGMNT_ZRTP</a></div><div class="ttdeci">@ RCE_SRTP_KMNGMNT_ZRTP</div><div class="ttdef"><b>Definition:</b> util.hh:135</div></div>
<div class="ttc" id="autil_8hh_html_a15b2d6364db6065a482c99827f4bd2afa4722105b4fd34467a56b8aca8fc03773"><div class="ttname"><a href="util_8hh.html#a15b2d6364db6065a482c99827f4bd2afa4722105b4fd34467a56b8aca8fc03773">RCE_SRTP_KMNGMNT_USER</a></div><div class="ttdeci">@ RCE_SRTP_KMNGMNT_USER</div><div class="ttdef"><b>Definition:</b> util.hh:145</div></div>
<div class="ttc" id="autil_8hh_html_a15b2d6364db6065a482c99827f4bd2afa4ddec7d182cec161d6b582589bc9baba"><div class="ttname"><a href="util_8hh.html#a15b2d6364db6065a482c99827f4bd2afa4ddec7d182cec161d6b582589bc9baba">RCE_SRTP_NULL_CIPHER</a></div><div class="ttdeci">@ RCE_SRTP_NULL_CIPHER</div><div class="ttdef"><b>Definition:</b> util.hh:197</div></div>
<div class="ttc" id="autil_8hh_html_a15b2d6364db6065a482c99827f4bd2afa5b0a8dbb22c20ebe8c0711541fb68a79"><div class="ttname"><a href="util_8hh.html#a15b2d6364db6065a482c99827f4bd2afa5b0a8dbb22c20ebe8c0711541fb68a79">RCE_FRAGMENT_GENERIC</a></div><div class="ttdeci">@ RCE_FRAGMENT_GENERIC</div><div class="ttdef"><b>Definition:</b> util.hh:181</div></div>
<div class="ttc" id="autil_8hh_html_a15b2d6364db6065a482c99827f4bd2afa5e9f19a63c964806ac9ff4ee089745e0"><div class="ttname"><a href="util_8hh.html#a15b2d6364db6065a482c99827f4bd2afa5e9f19a63c964806ac9ff4ee089745e0">RCE_NO_H26X_INTRA_DELAY</a></div><div class="ttdeci">@ RCE_NO_H26X_INTRA_DELAY</div><div class="ttdef"><b>Definition:</b> util.hh:167</div></div>
<div class="ttc" id="autil_8hh_html_a15b2d6364db6065a482c99827f4bd2afa75a655a9170ae88e07e993c1dd7ca4f7"><div class="ttname"><a href="util_8hh.html#a15b2d6364db6065a482c99827f4bd2afa75a655a9170ae88e07e993c1dd7ca4f7">RCE_H26X_PREPEND_SC</a></div><div class="ttdeci">@ RCE_H26X_PREPEND_SC</div><div class="ttdef"><b>Definition:</b> util.hh:215</div></div>
<div class="ttc" id="autil_8hh_html_a15b2d6364db6065a482c99827f4bd2afa820625b96886d955bc42e0cbc52cdd1e"><div class="ttname"><a href="util_8hh.html#a15b2d6364db6065a482c99827f4bd2afa820625b96886d955bc42e0cbc52cdd1e">RCE_SRTP_AUTHENTICATE_RTP</a></div><div class="ttdeci">@ RCE_SRTP_AUTHENTICATE_RTP</div><div class="ttdef"><b>Definition:</b> util.hh:205</div></div>
<div class="ttc" id="autil_8hh_html_a15b2d6364db6065a482c99827f4bd2afa8e66f45819774772a0156647d3788a95"><div class="ttname"><a href="util_8hh.html#a15b2d6364db6065a482c99827f4bd2afa8e66f45819774772a0156647d3788a95">RCE_HOLEPUNCH_KEEPALIVE</a></div><div class="ttdeci">@ RCE_HOLEPUNCH_KEEPALIVE</div><div class="ttdef"><b>Definition:</b> util.hh:221</div></div>
<div class="ttc" id="autil_8hh_html_a15b2d6364db6065a482c99827f4bd2afab1342138e5af3f03d6eaf1378382bf3d"><div class="ttname"><a href="util_8hh.html#a15b2d6364db6065a482c99827f4bd2afab1342138e5af3f03d6eaf1378382bf3d">RCE_RTCP</a></div><div class="ttdeci">@ RCE_RTCP</div><div class="ttdef"><b>Definition:</b> util.hh:212</div></div>
<div class="ttc" id="autil_8hh_html_a15b2d6364db6065a482c99827f4bd2afac03160668b92662fcb8d5b27bca3fbb0"><div class="ttname"><a href="util_8hh.html#a15b2d6364db6065a482c99827f4bd2afac03160668b92662fcb8d5b27bca3fbb0">RCE_NO_SYSTEM_CALL_CLUSTERING</a></div><div class="ttdeci">@ RCE_NO_SYSTEM_CALL_CLUSTERING</div><div class="ttdef"><b>Definition:</b> util.hh:194</div></div>
<div class="ttc" id="autil_8hh_html_a15b2d6364db6065a482c99827f4bd2afaddd5fdb170d7cc194e4165d3f9e9a1c1"><div class="ttname"><a href="util_8hh.html#a15b2d6364db6065a482c99827f4bd2afaddd5fdb170d7cc194e4165d3f9e9a1c1">RCE_SRTP_REPLAY_PROTECTION</a></div><div class="ttdeci">@ RCE_SRTP_REPLAY_PROTECTION</div><div class="ttdef"><b>Definition:</b> util.hh:208</div></div>
<div class="ttc" id="autil_8hh_html_a15b2d6364db6065a482c99827f4bd2afaedeac11cc80833b61b51ae32f787db73"><div class="ttname"><a href="util_8hh.html#a15b2d6364db6065a482c99827f4bd2afaedeac11cc80833b61b51ae32f787db73">RCE_SRTP_KEYSIZE_192</a></div><div class="ttdeci">@ RCE_SRTP_KEYSIZE_192</div><div class="ttdef"><b>Definition:</b> util.hh:224</div></div>
<div class="ttc" id="autil_8hh_html_a15b2d6364db6065a482c99827f4bd2afaf235cba606675b9c38284ee1a491696b"><div class="ttname"><a href="util_8hh.html#a15b2d6364db6065a482c99827f4bd2afaf235cba606675b9c38284ee1a491696b">RCE_SRTP</a></div><div class="ttdeci">@ RCE_SRTP</div><div class="ttdef"><b>Definition:</b> util.hh:125</div></div>
<div class="ttc" id="autil_8hh_html_a313c6640ac5ed9384184a94ec57a9a96"><div class="ttname"><a href="util_8hh.html#a313c6640ac5ed9384184a94ec57a9a96">RTP_FORMAT</a></div><div class="ttdeci">RTP_FORMAT</div><div class="ttdoc">These flags are given to uvgrtp::session::create_stream()</div><div class="ttdef"><b>Definition:</b> util.hh:85</div></div>
<div class="ttc" id="autil_8hh_html_a313c6640ac5ed9384184a94ec57a9a96a0e3d0414b29804783324399c8a42c85d"><div class="ttname"><a href="util_8hh.html#a313c6640ac5ed9384184a94ec57a9a96a0e3d0414b29804783324399c8a42c85d">RTP_FORMAT_H266</a></div><div class="ttdeci">@ RTP_FORMAT_H266</div><div class="ttdoc">H.266/VVC.</div><div class="ttdef"><b>Definition:</b> util.hh:89</div></div>
<div class="ttc" id="autil_8hh_html_a313c6640ac5ed9384184a94ec57a9a96a4e6ef095b4645cdc8aef241aad1f974b"><div class="ttname"><a href="util_8hh.html#a313c6640ac5ed9384184a94ec57a9a96a4e6ef095b4645cdc8aef241aad1f974b">RTP_FORMAT_OPUS</a></div><div class="ttdeci">@ RTP_FORMAT_OPUS</div><div class="ttdoc">Opus.</div><div class="ttdef"><b>Definition:</b> util.hh:90</div></div>
<div class="ttc" id="autil_8hh_html_a313c6640ac5ed9384184a94ec57a9a96a4ee0ab7d51bf50f8f5a5cb995ecc407b"><div class="ttname"><a href="util_8hh.html#a313c6640ac5ed9384184a94ec57a9a96a4ee0ab7d51bf50f8f5a5cb995ecc407b">RTP_FORMAT_H265</a></div><div class="ttdeci">@ RTP_FORMAT_H265</div><div class="ttdoc">H.265/HEVC.</div><div class="ttdef"><b>Definition:</b> util.hh:88</div></div>
<div class="ttc" id="autil_8hh_html_a313c6640ac5ed9384184a94ec57a9a96ad4b1be929d880baa2c2ca85c614f61b9"><div class="ttname"><a href="util_8hh.html#a313c6640ac5ed9384184a94ec57a9a96ad4b1be929d880baa2c2ca85c614f61b9">RTP_FORMAT_GENERIC</a></div><div class="ttdeci">@ RTP_FORMAT_GENERIC</div><div class="ttdoc">Generic format.</div><div class="ttdef"><b>Definition:</b> util.hh:86</div></div>
<div class="ttc" id="autil_8hh_html_a313c6640ac5ed9384184a94ec57a9a96ad785025a8de9a53f17dc84ec3eed85bd"><div class="ttname"><a href="util_8hh.html#a313c6640ac5ed9384184a94ec57a9a96ad785025a8de9a53f17dc84ec3eed85bd">RTP_FORMAT_H264</a></div><div class="ttdeci">@ RTP_FORMAT_H264</div><div class="ttdoc">H.264/AVC.</div><div class="ttdef"><b>Definition:</b> util.hh:87</div></div>
<div class="ttc" id="autil_8hh_html_aa6dc3f3578923d1afc40045e4cbe387b"><div class="ttname"><a href="util_8hh.html#aa6dc3f3578923d1afc40045e4cbe387b">RTP_ERROR</a></div><div class="ttdeci">RTP_ERROR</div><div class="ttdoc">RTP error codes.</div><div class="ttdef"><b>Definition:</b> util.hh:56</div></div>
<div class="ttc" id="autil_8hh_html_aa6dc3f3578923d1afc40045e4cbe387ba000c0166a0c38686389fc2eba0ddc458"><div class="ttname"><a href="util_8hh.html#aa6dc3f3578923d1afc40045e4cbe387ba000c0166a0c38686389fc2eba0ddc458">RTP_BIND_ERROR</a></div><div class="ttdeci">@ RTP_BIND_ERROR</div><div class="ttdoc">Failed to bind to interface.</div><div class="ttdef"><b>Definition:</b> util.hh:66</div></div>
<div class="ttc" id="autil_8hh_html_aa6dc3f3578923d1afc40045e4cbe387ba0759e9bb74c7a15ef09513547ed5cc2a"><div class="ttname"><a href="util_8hh.html#aa6dc3f3578923d1afc40045e4cbe387ba0759e9bb74c7a15ef09513547ed5cc2a">RTP_INITIALIZED</a></div><div class="ttdeci">@ RTP_INITIALIZED</div><div class="ttdoc">Object already initialized.</div><div class="ttdef"><b>Definition:</b> util.hh:71</div></div>
<div class="ttc" id="autil_8hh_html_aa6dc3f3578923d1afc40045e4cbe387ba0a18f9856d2dd5890bb6ec25e4acf631"><div class="ttname"><a href="util_8hh.html#aa6dc3f3578923d1afc40045e4cbe387ba0a18f9856d2dd5890bb6ec25e4acf631">RTP_NOT_FOUND</a></div><div class="ttdeci">@ RTP_NOT_FOUND</div><div class="ttdoc">Object not found.</div><div class="ttdef"><b>Definition:</b> util.hh:76</div></div>
<div class="ttc" id="autil_8hh_html_aa6dc3f3578923d1afc40045e4cbe387ba0d701531b2bb1c027f5e5bcc64ed29e1"><div class="ttname"><a href="util_8hh.html#aa6dc3f3578923d1afc40045e4cbe387ba0d701531b2bb1c027f5e5bcc64ed29e1">RTP_OK</a></div><div class="ttdeci">@ RTP_OK</div><div class="ttdoc">Success.</div><div class="ttdef"><b>Definition:</b> util.hh:63</div></div>
<div class="ttc" id="autil_8hh_html_aa6dc3f3578923d1afc40045e4cbe387ba32d67254c4da35568e7007ec3825f98a"><div class="ttname"><a href="util_8hh.html#aa6dc3f3578923d1afc40045e4cbe387ba32d67254c4da35568e7007ec3825f98a">RTP_NOT_INITIALIZED</a></div><div class="ttdeci">@ RTP_NOT_INITIALIZED</div><div class="ttdoc">Object has not been initialized.</div><div class="ttdef"><b>Definition:</b> util.hh:72</div></div>
<div class="ttc" id="autil_8hh_html_aa6dc3f3578923d1afc40045e4cbe387ba4cdd3c5db294a4f05294b264afbf678b"><div class="ttname"><a href="util_8hh.html#aa6dc3f3578923d1afc40045e4cbe387ba4cdd3c5db294a4f05294b264afbf678b">RTP_INVALID_VALUE</a></div><div class="ttdeci">@ RTP_INVALID_VALUE</div><div class="ttdoc">Invalid value.</div><div class="ttdef"><b>Definition:</b> util.hh:67</div></div>
<div class="ttc" id="autil_8hh_html_aa6dc3f3578923d1afc40045e4cbe387ba6c47e86944dbed4d33531236a6e28079"><div class="ttname"><a href="util_8hh.html#aa6dc3f3578923d1afc40045e4cbe387ba6c47e86944dbed4d33531236a6e28079">RTP_SEND_ERROR</a></div><div class="ttdeci">@ RTP_SEND_ERROR</div><div class="ttdoc">System call send(2) or one of its derivatives failed.</div><div class="ttdef"><b>Definition:</b> util.hh:68</div></div>
<div class="ttc" id="autil_8hh_html_aa6dc3f3578923d1afc40045e4cbe387ba6d62ec0a7250a3db7c0f3a13280ecc65"><div class="ttname"><a href="util_8hh.html#aa6dc3f3578923d1afc40045e4cbe387ba6d62ec0a7250a3db7c0f3a13280ecc65">RTP_AUTH_TAG_MISMATCH</a></div><div class="ttdeci">@ RTP_AUTH_TAG_MISMATCH</div><div class="ttdoc">Authentication tag does not match the RTP packet contents.</div><div class="ttdef"><b>Definition:</b> util.hh:77</div></div>
<div class="ttc" id="autil_8hh_html_aa6dc3f3578923d1afc40045e4cbe387ba756d5cd372b045f069a493ed2f2cfa22"><div class="ttname"><a href="util_8hh.html#aa6dc3f3578923d1afc40045e4cbe387ba756d5cd372b045f069a493ed2f2cfa22">RTP_NOT_SUPPORTED</a></div><div class="ttdeci">@ RTP_NOT_SUPPORTED</div><div class="ttdoc">Method/version/extension not supported.</div><div class="ttdef"><b>Definition:</b> util.hh:73</div></div>
<div class="ttc" id="autil_8hh_html_aa6dc3f3578923d1afc40045e4cbe387ba80aa5b74c1e252c2ef49e0796d4183d3"><div class="ttname"><a href="util_8hh.html#aa6dc3f3578923d1afc40045e4cbe387ba80aa5b74c1e252c2ef49e0796d4183d3">RTP_SSRC_COLLISION</a></div><div class="ttdeci">@ RTP_SSRC_COLLISION</div><div class="ttdoc">SSRC collision detected.</div><div class="ttdef"><b>Definition:</b> util.hh:70</div></div>
<div class="ttc" id="autil_8hh_html_aa6dc3f3578923d1afc40045e4cbe387baa499befa487c22503360adffc590f33b"><div class="ttname"><a href="util_8hh.html#aa6dc3f3578923d1afc40045e4cbe387baa499befa487c22503360adffc590f33b">RTP_RECV_ERROR</a></div><div class="ttdeci">@ RTP_RECV_ERROR</div><div class="ttdoc">System call recv(2) or one of its derivatives failed.</div><div class="ttdef"><b>Definition:</b> util.hh:74</div></div>
<div class="ttc" id="autil_8hh_html_aa6dc3f3578923d1afc40045e4cbe387bab392a7774c551eed903855248760ad06"><div class="ttname"><a href="util_8hh.html#aa6dc3f3578923d1afc40045e4cbe387bab392a7774c551eed903855248760ad06">RTP_SOCKET_ERROR</a></div><div class="ttdeci">@ RTP_SOCKET_ERROR</div><div class="ttdoc">Failed to create socket.</div><div class="ttdef"><b>Definition:</b> util.hh:65</div></div>
<div class="ttc" id="autil_8hh_html_aa6dc3f3578923d1afc40045e4cbe387bac54e582250aec15bf2aea189ccbb0348"><div class="ttname"><a href="util_8hh.html#aa6dc3f3578923d1afc40045e4cbe387bac54e582250aec15bf2aea189ccbb0348">RTP_MEMORY_ERROR</a></div><div class="ttdeci">@ RTP_MEMORY_ERROR</div><div class="ttdoc">Memory allocation failed.</div><div class="ttdef"><b>Definition:</b> util.hh:69</div></div>
<div class="ttc" id="autil_8hh_html_aa6dc3f3578923d1afc40045e4cbe387bacb40716d1ab0663c0cce56f6d03f0902"><div class="ttname"><a href="util_8hh.html#aa6dc3f3578923d1afc40045e4cbe387bacb40716d1ab0663c0cce56f6d03f0902">RTP_TIMEOUT</a></div><div class="ttdeci">@ RTP_TIMEOUT</div><div class="ttdoc">Operation timed out.</div><div class="ttdef"><b>Definition:</b> util.hh:75</div></div>
<div class="ttc" id="autil_8hh_html_aa6dc3f3578923d1afc40045e4cbe387bafde486de26be732acf472480e3693b19"><div class="ttname"><a href="util_8hh.html#aa6dc3f3578923d1afc40045e4cbe387bafde486de26be732acf472480e3693b19">RTP_GENERIC_ERROR</a></div><div class="ttdeci">@ RTP_GENERIC_ERROR</div><div class="ttdoc">Generic error condition.</div><div class="ttdef"><b>Definition:</b> util.hh:64</div></div>
<div class="ttc" id="autil_8hh_html_aa98d9238629e33567e73af0d239e587f"><div class="ttname"><a href="util_8hh.html#aa98d9238629e33567e73af0d239e587f">RTP_CTX_CONFIGURATION_FLAGS</a></div><div class="ttdeci">RTP_CTX_CONFIGURATION_FLAGS</div><div class="ttdoc">RTP context configuration flags.</div><div class="ttdef"><b>Definition:</b> util.hh:239</div></div>
<div class="ttc" id="autil_8hh_html_aa98d9238629e33567e73af0d239e587fa5ac1245e18a420489083adddfa97b135"><div class="ttname"><a href="util_8hh.html#aa98d9238629e33567e73af0d239e587fa5ac1245e18a420489083adddfa97b135">RCC_PKT_MAX_DELAY</a></div><div class="ttdeci">@ RCC_PKT_MAX_DELAY</div><div class="ttdef"><b>Definition:</b> util.hh:264</div></div>
<div class="ttc" id="autil_8hh_html_aa98d9238629e33567e73af0d239e587fa7667fb72b42a2c11991b4879619f9f83"><div class="ttname"><a href="util_8hh.html#aa98d9238629e33567e73af0d239e587fa7667fb72b42a2c11991b4879619f9f83">RCC_MTU_SIZE</a></div><div class="ttdeci">@ RCC_MTU_SIZE</div><div class="ttdef"><b>Definition:</b> util.hh:278</div></div>
<div class="ttc" id="autil_8hh_html_aa98d9238629e33567e73af0d239e587fac52afca9d1a8c24b1a788bc5b8524663"><div class="ttname"><a href="util_8hh.html#aa98d9238629e33567e73af0d239e587fac52afca9d1a8c24b1a788bc5b8524663">RCC_UDP_RCV_BUF_SIZE</a></div><div class="ttdeci">@ RCC_UDP_RCV_BUF_SIZE</div><div class="ttdef"><b>Definition:</b> util.hh:248</div></div>
<div class="ttc" id="autil_8hh_html_aa98d9238629e33567e73af0d239e587fac758a522806ada30386b262660f30617"><div class="ttname"><a href="util_8hh.html#aa98d9238629e33567e73af0d239e587fac758a522806ada30386b262660f30617">RCC_DYN_PAYLOAD_TYPE</a></div><div class="ttdeci">@ RCC_DYN_PAYLOAD_TYPE</div><div class="ttdef"><b>Definition:</b> util.hh:268</div></div>
<div class="ttc" id="autil_8hh_html_aa98d9238629e33567e73af0d239e587fad4eba6c62183db35dd4bd0e09ddd107b"><div class="ttname"><a href="util_8hh.html#aa98d9238629e33567e73af0d239e587fad4eba6c62183db35dd4bd0e09ddd107b">RCC_UDP_SND_BUF_SIZE</a></div><div class="ttdeci">@ RCC_UDP_SND_BUF_SIZE</div><div class="ttdef"><b>Definition:</b> util.hh:256</div></div>
<div class="ttc" id="autil_8hh_html_af03a75996471fc531742cd640c7caf2d"><div class="ttname"><a href="util_8hh.html#af03a75996471fc531742cd640c7caf2d">RTP_FLAGS</a></div><div class="ttdeci">RTP_FLAGS</div><div class="ttdoc">These flags are given to uvgrtp::media_stream::push_frame() and they can be OR'ed together.</div><div class="ttdef"><b>Definition:</b> util.hh:99</div></div>
<div class="ttc" id="autil_8hh_html_af03a75996471fc531742cd640c7caf2da084c095dae54bbbc6d9509568c58f9a6"><div class="ttname"><a href="util_8hh.html#af03a75996471fc531742cd640c7caf2da084c095dae54bbbc6d9509568c58f9a6">RTP_NO_FLAGS</a></div><div class="ttdeci">@ RTP_NO_FLAGS</div><div class="ttdef"><b>Definition:</b> util.hh:101</div></div>
<div class="ttc" id="autil_8hh_html_af03a75996471fc531742cd640c7caf2dab1d5797a23c37a33168046a2ae6aef6a"><div class="ttname"><a href="util_8hh.html#af03a75996471fc531742cd640c7caf2dab1d5797a23c37a33168046a2ae6aef6a">RTP_COPY</a></div><div class="ttdeci">@ RTP_COPY</div><div class="ttdef"><b>Definition:</b> util.hh:107</div></div>
<div class="ttc" id="autil_8hh_html_af03a75996471fc531742cd640c7caf2dada7e8bc5f5542554ad7de9d74967616f"><div class="ttname"><a href="util_8hh.html#af03a75996471fc531742cd640c7caf2dada7e8bc5f5542554ad7de9d74967616f">RTP_SLICE</a></div><div class="ttdeci">@ RTP_SLICE</div><div class="ttdef"><b>Definition:</b> util.hh:104</div></div>
</div><!-- fragment --></div><!-- contents -->
<!-- start footer part -->
<hr class="footer"/><address class="footer"><small>
Generated by&#160;<a href="https://www.doxygen.org/index.html"><img class="footer" src="doxygen.svg" width="104" height="31" alt="doxygen"/></a> 1.9.1
</small></address>
</body>
</html>
